#include <stdio.h>

//https://www.nowcoder.com/practice/a6d1081e0c9a42f19e42ed6cd91556c1?tpId=290&tqId=309114&ru=/exam/oj/ta&qru=/ta/beginner-programmers/question-ranking&sourceUrl=%2Fexam%2Foj%2Fta%3Fpage%3D1%26tpId%3D290%26type%3D290

int main() {
    int num = 0;
    while(~scanf("%d", &num)) {
        int count = 1;
        for (; num >= 0; num--, count++) {
            for (int i = 0; i < 2 * num + count; i++) {
                if (i < 2 * num) {
                    printf(" ");
                } else {
                    printf("*");
                }
            }
            printf("\n");
        }
        for (num++, count--; count > 1; num++, count--) {
            for (int i = 0; i < 2 * num + count + 1; i++) {
                if (i < 2 * (num + 1)) {
                    printf(" ");
                } else {
                    printf("*");
                }
            }
            printf("\n");
        }
    }
    return 0;
}